<template>
        <!-- <h1>欢迎页</h1> -->
        <div class="tab">
            <el-table
                    :data="arr"
                    border
                    style="width: 100%">
                <el-table-column
                    prop="username"
                    label="登入账户"
                    width="180">
                </el-table-column>
                <el-table-column
                    prop="lastLogin.ip"
                    label="上次登入ip"
                    width="180">
                </el-table-column>
                <el-table-column
                    prop="lastLogin.loginTime"
                    label="上次登入时间"
                    sortable>
                </el-table-column>
                <el-table-column
                    prop="nowLogin.ip"
                    label="本次登入ip">
                </el-table-column>
                <el-table-column
                    prop="nowLogin.loginTime"
                    label="本次登入ip">
                </el-table-column>
            </el-table>
        </div>
</template>

<script>
import {loginLog} from "../../../api/users"
  export default {
    data() {
      return {
        arr:[],
      }
    },
    mounted(){
      this.SSFn()
    },
    methods:{
     async SSFn(){
      let res = await loginLog()
      console.log(res);
      this.arr = res.data.data
      console.log(this.arr);
      }
    },
    meta: {
        title: 'glsy',
        name:"管理首页",
        icon: 'iconfont icon-shouye1'
    }
  }
</script>

<style lang="less" scoped>
/deep/ .has-gutter{
    line-height: 16px;
}
/deep/ .el-table .el-table__cell{
    text-align: center;
}
</style>